<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style>

        body{
            height: 6000px;
        }
        p{
            margin-top: 10px;
        }

        div{
            position: sticky;
            top: 30px;
        }
    </style>
</head>
<body>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>

    <div class="">粘性定位</div>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>
    <p>啊的安德森史蒂夫史蒂夫</p>
</body>
</html>
